<?php
//print_r($_GET);die;//Array ( [ids] => 34,3, )
include_once("./function.php");
extract($_GET);//$ids
$ids=rtrim($ids,",");
//echo $ids;die;//34,3
$one=explode(",",$ids);
//print_r($one);die;//Array ( [0] => 34 [1] => 3 )
function getValue($arr)
{
 foreach($arr as $key => $value)
 {
  if(is_array($value)){
   getValue($value);
 }
 else
 {
   echo $value."<br>";
 }
 }
}
//getValue($one);
//print_r($one[1]);die;

for($i=0;$i<count($one);$i++)
{
	$sql="select * from ts_sysconfig where sys_id=$one[$i]";
	//echo $sql;die;
	$res=mysqli_query($link,$sql);
	if(is_object($res))
	{
		if(mysqli_num_rows($res)==1)
		{
			$list=$res1=mysqli_fetch_assoc($res);	
		}
	}
	if($one[$i]<=3)
	{
		msg("标题关键字和描述不能删除","sys_conf.php");exit;
	}
	else
	{
		$sql="delete from ts_sysconfig where sys_id=$one[$i]";
		$res=mysqli_query($link,$sql);
		if($res)
		{
			if(mysqli_affected_rows($link)==1)
			{
				msg('删除成功','sys_conf.php');
			}
			else
			{
				msg('删除失败','sys_conf.php');exit;
			}
		}
	}
}
?>


 